
package com.quartet.utils.enums;

import lombok.AllArgsConstructor;
import lombok.Getter;

/**
 * <p>
 * 区域类型 1:当前区域 2：历史区域
 * </p>
 * @author Zheng Jie
 * @date 2020-05-07
 */
@Getter
@AllArgsConstructor
public enum RegionTypeEnum {

    CURRENT_AREA("1", "当前区域"),
    HISTORICAL_AREA("2", "历史区域");
    private final String value;
    private final String description;

    public static RegionTypeEnum find(String val) {
        for (RegionTypeEnum dataScopeEnum : RegionTypeEnum.values()) {
            if (val.equals(dataScopeEnum.getValue())) {
                return dataScopeEnum;
            }
        }
        return null;
    }

}
